/*
 * @Author: Li Zengkun
 * @Date: 2022-09-12 19:33:36
 * @LastEditors: Li Zengkun
 * @LastEditTime: 2022-09-16 16:10:30
 * @Description: article api
 */
import axios from 'axios'

// 添加新的文章
const release = (data) => axios.post('/article/release', data)

// 删除指定id的文章
const remove = (data) => axios.post('/article/remove', data)

// 给指定id文章标记标签
const tag = (data) => axios.post('/article/tag', data)

// 编辑指定id文章
const edit = (data) => axios.post('/article/edit', data)

// 获取指定id的文章详情
const detail = (params) => axios.get('/article/detail', { params })

// 获取文章列表
const list = (params) => axios.get('/article/list', { params })

export default {
    release,
    remove,
    tag,
    edit,
    detail,
    list
}